<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>我的媒体 - 拖拽式建站平台</title>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
        }

        :root {
            --sidebar-width: 240px;
            --header-height: 64px;
            --primary-color: #3498db;
            --secondary-color: #2c3e50;
            --bg-color: #f5f6f7;
            --card-bg: #ffffff;
            --text-primary: #18191c;
            --text-secondary: #61666d;
            --text-muted: #9499a0;
            --border-color: #e3e5e7;
            --success-color: #27ae60;
            --warning-color: #f39c12;
            --danger-color: #e74c3c;
        }

        body {
            background-color: var(--bg-color);
            color: var(--text-primary);
            display: flex;
            flex-direction: column;
            height: 100vh;
            overflow: hidden;
        }

        /* 顶部导航栏 */
        .header {
            height: var(--header-height);
            background: var(--card-bg);
            box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 0 20px;
            border-bottom: 1px solid var(--border-color);
            z-index: 100;
        }

        .header-left {
            display: flex;
            align-items: center;
        }

        .sidebar-toggle {
            margin-right: 16px;
            cursor: pointer;
            color: var(--text-secondary);
            font-size: 18px;
        }

        .logo {
            font-size: 18px;
            font-weight: 600;
            color: var(--text-primary);
            display: flex;
            align-items: center;
        }

        .logo i {
            margin-right: 10px;
            color: var(--primary-color);
        }

        .header-right {
            display: flex;
            align-items: center;
        }

        .header-action {
            margin-left: 16px;
            color: var(--text-secondary);
            cursor: pointer;
            position: relative;
        }

        .header-action:hover {
            color: var(--primary-color);
        }

        .badge {
            position: absolute;
            top: -5px;
            right: -5px;
            background: var(--danger-color);
            color: white;
            font-size: 11px;
            width: 16px;
            height: 16px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .user-menu {
            display: flex;
            align-items: center;
            margin-left: 20px;
            cursor: pointer;
        }

        .user-avatar {
            width: 36px;
            height: 36px;
            border-radius: 50%;
            background: var(--primary-color);
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-left: 12px;
        }

        /* 主内容区域 */
        .main-container {
            display: flex;
            flex: 1;
            overflow: hidden;
        }

        /* 侧边栏 */
        .sidebar {
            width: var(--sidebar-width);
            background: var(--card-bg);
            border-right: 1px solid var(--border-color);
            overflow-y: auto;
            transition: all 0.3s ease;
        }

        .sidebar-menu {
            padding: 16px 0;
        }

        .menu-title {
            padding: 10px 20px;
            font-size: 13px;
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }

        .menu-item {
            display: flex;
            align-items: center;
            padding: 12px 20px;
            color: var(--text-secondary);
            text-decoration: none;
            transition: all 0.3s ease;
            border-left: 3px solid transparent;
        }

        .menu-item:hover {
            background: rgba(52, 152, 219, 0.1);
            color: var(--primary-color);
        }

        .menu-item.active {
            background: rgba(52, 152, 219, 0.1);
            color: var(--primary-color);
            border-left-color: var(--primary-color);
        }

        .menu-item i {
            margin-right: 12px;
            width: 18px;
            text-align: center;
        }

        /* 内容区域 */
        .content {
            flex: 1;
            padding: 20px;
            overflow-y: auto;
        }

        .page-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 24px;
        }

        .page-title {
            font-size: 24px;
            font-weight: 600;
        }

        .page-actions .btn {
            margin-left: 10px;
        }

        /* 筛选和搜索区域 */
        .filter-bar {
            background: var(--card-bg);
            border-radius: 4px;
            padding: 16px 20px;
            margin-bottom: 20px;
            display: flex;
            flex-wrap: wrap;
            gap: 16px;
            align-items: center;
            box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
        }

        .search-box {
            position: relative;
            flex: 1;
            min-width: 200px;
        }

        .search-input {
            width: 100%;
            padding: 10px 16px 10px 40px;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            font-size: 14px;
        }

        .search-icon {
            position: absolute;
            left: 12px;
            top: 50%;
            transform: translateY(-50%);
            color: var(--text-muted);
        }

        .filter-group {
            display: flex;
            align-items: center;
        }

        .filter-label {
            font-size: 14px;
            color: var(--text-secondary);
            margin-right: 8px;
        }

        .filter-select {
            padding: 8px 12px;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            background: white;
            font-size: 14px;
            min-width: 120px;
        }

        .view-toggle {
            display: flex;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            overflow: hidden;
        }

        .view-btn {
            padding: 8px 12px;
            background: white;
            border: none;
            cursor: pointer;
            color: var(--text-secondary);
        }

        .view-btn.active {
            background: var(--primary-color);
            color: white;
        }

        /* 媒体库区域 */
        .media-container {
            background: var(--card-bg);
            border-radius: 4px;
            overflow: hidden;
            box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
        }

        .media-header {
            padding: 16px 20px;
            border-bottom: 1px solid var(--border-color);
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .media-title {
            font-size: 16px;
            font-weight: 500;
        }

        .media-count {
            font-size: 14px;
            color: var(--text-muted);
        }

        /* 网格视图 */
        .media-grid {
            padding: 20px;
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
            gap: 20px;
        }

        .media-item {
            border: 1px solid var(--border-color);
            border-radius: 6px;
            overflow: hidden;
            transition: all 0.3s ease;
            cursor: pointer;
            background: white;
        }

        .media-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        .media-item.selected {
            border-color: var(--primary-color);
            box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
        }

        .media-thumbnail {
            height: 150px;
            background: #f9fafc;
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
            position: relative;
        }

        .media-thumbnail img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .media-thumbnail i {
            font-size: 40px;
            color: var(--text-muted);
        }

        .media-badge {
            position: absolute;
            top: 8px;
            right: 8px;
            background: rgba(0, 0, 0, 0.6);
            color: white;
            font-size: 11px;
            padding: 2px 6px;
            border-radius: 10px;
        }

        .media-info {
            padding: 12px;
        }

        .media-name {
            font-weight: 500;
            margin-bottom: 4px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .media-meta {
            display: flex;
            justify-content: space-between;
            font-size: 12px;
            color: var(--text-muted);
        }

        /* 列表视图 */
        .media-list {
            display: none;
            padding: 0;
        }

        .media-list-item {
            display: flex;
            padding: 12px 20px;
            border-bottom: 1px solid var(--border-color);
            align-items: center;
            transition: background 0.3s ease;
        }

        .media-list-item:hover {
            background: rgba(52, 152, 219, 0.05);
        }

        .media-list-item:last-child {
            border-bottom: none;
        }

        .media-list-thumb {
            width: 60px;
            height: 60px;
            border-radius: 4px;
            background: #f9fafc;
            margin-right: 16px;
            flex-shrink: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
        }

        .media-list-thumb img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .media-list-thumb i {
            font-size: 24px;
            color: var(--text-muted);
        }

        .media-list-info {
            flex: 1;
        }

        .media-list-name {
            font-weight: 500;
            margin-bottom: 4px;
        }

        .media-list-details {
            display: flex;
            gap: 16px;
            font-size: 13px;
            color: var(--text-secondary);
        }

        .media-list-meta {
            display: flex;
            align-items: center;
        }

        .media-list-meta i {
            margin-right: 4px;
        }

        .media-list-actions {
            display: flex;
            gap: 8px;
        }

        /* 上传区域 */
        .upload-area {
            background: var(--card-bg);
            border-radius: 4px;
            padding: 20px;
            margin-bottom: 20px;
            box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
            text-align: center;
            border: 2px dashed var(--border-color);
            transition: all 0.3s ease;
        }

        .upload-area:hover {
            border-color: var(--primary-color);
        }

        .upload-icon {
            font-size: 40px;
            color: var(--primary-color);
            margin-bottom: 16px;
        }

        .upload-text {
            margin-bottom: 16px;
            color: var(--text-secondary);
        }

        .upload-hint {
            font-size: 13px;
            color: var(--text-muted);
            margin-bottom: 16px;
        }

        /* 空状态 */
        .empty-state {
            padding: 60px 20px;
            text-align: center;
            color: var(--text-muted);
        }

        .empty-state i {
            font-size: 64px;
            margin-bottom: 16px;
            color: #d1d5db;
        }

        .empty-state p {
            margin-bottom: 24px;
            font-size: 16px;
        }

        /* 按钮样式 */
        .btn {
            padding: 8px 16px;
            border: none;
            border-radius: 4px;
            font-size: 14px;
            font-weight: 500;
            cursor: pointer;
            transition: all 0.3s ease;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }

        .btn i {
            margin-right: 6px;
        }

        .btn-primary {
            background: var(--primary-color);
            color: white;
        }

        .btn-primary:hover {
            background: #2980b9;
        }

        .btn-outline {
            background: transparent;
            border: 1px solid var(--border-color);
            color: var(--text-secondary);
        }

        .btn-outline:hover {
            background: #f5f7fa;
        }

        .btn-success {
            background: var(--success-color);
            color: white;
        }

        .btn-success:hover {
            background: #219653;
        }

        .btn-danger {
            background: var(--danger-color);
            color: white;
        }

        .btn-danger:hover {
            background: #c0392b;
        }

        .btn-sm {
            padding: 4px 8px;
            font-size: 13px;
        }

        .btn-icon {
            width: 32px;
            height: 32px;
            padding: 0;
            justify-content: center;
        }

        .btn-icon i {
            margin-right: 0;
        }

        /* 响应式设计 */
        @media (max-width: 992px) {
            .sidebar {
                position: fixed;
                left: -var(--sidebar-width);
                top: var(--header-height);
                bottom: 0;
                z-index: 90;
            }

            .sidebar.open {
                left: 0;
            }

            .overlay {
                position: fixed;
                top: var(--header-height);
                left: 0;
                right: 0;
                bottom: 0;
                background: rgba(0, 0, 0, 0.5);
                z-index: 80;
                display: none;
            }

            .overlay.open {
                display: block;
            }
        }

        @media (max-width: 768px) {
            .filter-bar {
                flex-direction: column;
                align-items: stretch;
            }

            .search-box {
                min-width: auto;
            }

            .filter-group {
                width: 100%;
                justify-content: space-between;
            }

            .media-grid {
                grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
                gap: 15px;
                padding: 15px;
            }

            .media-list-details {
                flex-direction: column;
                gap: 4px;
            }

            .page-header {
                flex-direction: column;
                align-items: flex-start;
            }

            .page-actions {
                margin-top: 16px;
                width: 100%;
                display: flex;
                justify-content: space-between;
            }

            .page-actions .btn {
                margin-left: 0;
                flex: 1;
                margin: 0 5px;
            }
        }
    </style>
</head>

<body>
    <!-- 顶部导航栏 -->
    <div class="header">
        <div class="header-left">
            <div class="sidebar-toggle">
                <i class="fas fa-bars"></i>
            </div>
            <div class="logo">
                <i class="fas fa-puzzle-piece"></i>
                拖拽建站平台
            </div>
        </div>

        <div class="header-right">
            <div class="header-action">
                <i class="fas fa-bell"></i>
                <span class="badge">3</span>
            </div>

            <div class="header-action">
                <i class="fas fa-envelope"></i>
                <span class="badge">5</span>
            </div>

            <div class="user-menu">
                <span>张三</span>
                <div class="user-avatar">
                    <i class="fas fa-user"></i>
                </div>
            </div>
        </div>
    </div>

    <!-- 主内容区域 -->
    <div class="main-container">
        <!-- 侧边栏 -->
        <div class="sidebar">
            <div class="sidebar-menu">
                <div class="menu-title">用户中心</div>
                <a href="#" class="menu-item">
                    <i class="fas fa-user-circle"></i>
                    <span>个人信息</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-shield-alt"></i>
                    <span>账户安全</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-globe"></i>
                    <span>我的网站</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-file-alt"></i>
                    <span>我的页面</span>
                </a>

                <div class="menu-title">内容管理</div>
                <a href="#" class="menu-item">
                    <i class="fas fa-newspaper"></i>
                    <span>我的文章</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-box"></i>
                    <span>我的产品</span>
                </a>
                <a href="#" class="menu-item active">
                    <i class="fas fa-images"></i>
                    <span>我的媒体</span>
                </a>

                <div class="menu-title">交易管理</div>
                <a href="#" class="menu-item">
                    <i class="fas fa-credit-card"></i>
                    <span>我的订单</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-money-bill-wave"></i>
                    <span>支付记录</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-gift"></i>
                    <span>优惠券</span>
                </a>

                <div class="menu-title">消息中心</div>
                <a href="#" class="menu-item">
                    <i class="fas fa-bell"></i>
                    <span>消息通知</span>
                </a>
                <a href="#" class="menu-item">
                    <i class="fas fa-comments"></i>
                    <span>站内信</span>
                </a>
            </div>
        </div>

        <!-- 内容区域 -->
        <div class="content">
            <div class="page-header">
                <h1 class="page-title">我的媒体</h1>
                <div class="page-actions">
                    <button class="btn btn-outline">
                        <i class="fas fa-download"></i> 批量下载
                    </button>
                    <button class="btn btn-primary">
                        <i class="fas fa-plus"></i> 上传媒体
                    </button>
                </div>
            </div>

            <!-- 上传区域 -->
            <div class="upload-area">
                <div class="upload-icon">
                    <i class="fas fa-cloud-upload-alt"></i>
                </div>
                <div class="upload-text">
                    拖放文件到此处或点击上传
                </div>
                <div class="upload-hint">
                    支持 JPG, PNG, GIF, MP4 等格式，单个文件不超过 10MB
                </div>
                <button class="btn btn-primary">
                    <i class="fas fa-upload"></i> 选择文件
                </button>
            </div>

            <!-- 筛选和搜索区域 -->
            <div class="filter-bar">
                <div class="search-box">
                    <i class="fas fa-search search-icon"></i>
                    <input type="text" class="search-input" placeholder="搜索媒体文件...">
                </div>

                <div class="filter-group">
                    <span class="filter-label">类型:</span>
                    <select class="filter-select">
                        <option>全部类型</option>
                        <option>图片</option>
                        <option>视频</option>
                        <option>文档</option>
                        <option>其他</option>
                    </select>
                </div>

                <div class="filter-group">
                    <span class="filter-label">排序:</span>
                    <select class="filter-select">
                        <option>最新上传</option>
                        <option>名称 A-Z</option>
                        <option>名称 Z-A</option>
                        <option>文件大小</option>
                    </select>
                </div>

                <div class="view-toggle">
                    <button class="view-btn active" id="gridView">
                        <i class="fas fa-th"></i>
                    </button>
                    <button class="view-btn" id="listView">
                        <i class="fas fa-list"></i>
                    </button>
                </div>
            </div>

            <!-- 媒体库区域 -->
            <div class="media-container">
                <div class="media-header">
                    <div class="media-title">媒体文件</div>
                    <div class="media-count">共 8 个文件</div>
                </div>

                <!-- 网格视图 -->
                <div class="media-grid" id="mediaGridView">
                    <div class="media-item">
                        <div class="media-thumbnail">
                            <img src="https://placehold.co/300x200" alt="产品展示图">
                            <span class="media-badge">图片</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">product-showcase.jpg</div>
                            <div class="media-meta">
                                <span>1.2 MB</span>
                                <span>2023-08-15</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <img src="https://placehold.co/300x200" alt="公司Logo">
                            <span class="media-badge">图片</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">company-logo.png</div>
                            <div class="media-meta">
                                <span>0.8 MB</span>
                                <span>2023-08-20</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <i class="fas fa-video"></i>
                            <span class="media-badge">视频</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">product-demo.mp4</div>
                            <div class="media-meta">
                                <span>8.5 MB</span>
                                <span>2023-08-25</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <img src="https://placehold.co/300x200" alt="团队照片">
                            <span class="media-badge">图片</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">team-photo.jpg</div>
                            <div class="media-meta">
                                <span>2.1 MB</span>
                                <span>2023-09-01</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <i class="fas fa-file-pdf"></i>
                            <span class="media-badge">文档</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">product-catalog.pdf</div>
                            <div class="media-meta">
                                <span>3.7 MB</span>
                                <span>2023-09-03</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <img src="https://placehold.co/300x200" alt="背景图片">
                            <span class="media-badge">图片</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">background-texture.jpg</div>
                            <div class="media-meta">
                                <span>1.5 MB</span>
                                <span>2023-09-05</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <i class="fas fa-file-alt"></i>
                            <span class="media-badge">文档</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">user-manual.docx</div>
                            <div class="media-meta">
                                <span>0.9 MB</span>
                                <span>2023-09-07</span>
                            </div>
                        </div>
                    </div>

                    <div class="media-item">
                        <div class="media-thumbnail">
                            <i class="fas fa-video"></i>
                            <span class="media-badge">视频</span>
                        </div>
                        <div class="media-info">
                            <div class="media-name">tutorial-video.mp4</div>
                            <div class="media-meta">
                                <span>12.4 MB</span>
                                <span>2023-09-10</span>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- 列表视图 -->
                <div class="media-list" id="mediaListView">
                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <img src="https://placehold.co/60x60" alt="产品展示图">
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">product-showcase.jpg</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-image"></i> 图片
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 1.2 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-08-15
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-ruler-combined"></i> 1200×800
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <img src="https://placehold.co/60x60" alt="公司Logo">
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">company-logo.png</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-image"></i> 图片
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 0.8 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-08-20
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-ruler-combined"></i> 800×800
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <i class="fas fa-video"></i>
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">product-demo.mp4</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-video"></i> 视频
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 8.5 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-08-25
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-clock"></i> 02:30
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <img src="https://placehold.co/60x60" alt="团队照片">
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">team-photo.jpg</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-image"></i> 图片
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 2.1 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-09-01
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-ruler-combined"></i> 1920×1080
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <i class="fas fa-file-pdf"></i>
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">product-catalog.pdf</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-file-pdf"></i> 文档
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 3.7 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-09-03
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-file"></i> 24页
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <img src="https://placehold.co/60x60" alt="背景图片">
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">background-texture.jpg</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-image"></i> 图片
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 1.5 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-09-05
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-ruler-combined"></i> 2000×1200
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <i class="fas fa-file-alt"></i>
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">user-manual.docx</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-file-word"></i> 文档
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 0.9 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-09-07
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-file"></i> 12页
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>

                    <div class="media-list-item">
                        <div class="media-list-thumb">
                            <i class="fas fa-video"></i>
                        </div>
                        <div class="media-list-info">
                            <div class="media-list-name">tutorial-video.mp4</div>
                            <div class="media-list-details">
                                <div class="media-list-meta">
                                    <i class="fas fa-video"></i> 视频
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-weight-hanging"></i> 12.4 MB
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-calendar"></i> 2023-09-10
                                </div>
                                <div class="media-list-meta">
                                    <i class="fas fa-clock"></i> 05:45
                                </div>
                            </div>
                        </div>
                        <div class="media-list-actions">
                            <button class="btn btn-icon btn-outline" title="预览">
                                <i class="fas fa-eye"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="下载">
                                <i class="fas fa-download"></i>
                            </button>
                            <button class="btn btn-icon btn-outline" title="删除">
                                <i class="fas fa-trash"></i>
                            </button>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script>
        // 视图切换功能
        const gridViewBtn = document.getElementById('gridView');
        const listViewBtn = document.getElementById('listView');
        const mediaGridView = document.getElementById('mediaGridView');
        const mediaListView = document.getElementById('mediaListView');

        gridViewBtn.addEventListener('click', () => {
            gridViewBtn.classList.add('active');
            listViewBtn.classList.remove('active');
            mediaGridView.style.display = 'grid';
            mediaListView.style.display = 'none';
        });

        listViewBtn.addEventListener('click', () => {
            listViewBtn.classList.add('active');
            gridViewBtn.classList.remove('active');
            mediaGridView.style.display = 'none';
            mediaListView.style.display = 'block';
        });

        // 侧边栏切换功能
        const sidebarToggle = document.querySelector('.sidebar-toggle');
        const sidebar = document.querySelector('.sidebar');
        const overlay = document.createElement('div');
        overlay.className = 'overlay';
        document.body.appendChild(overlay);

        sidebarToggle.addEventListener('click', () => {
            sidebar.classList.toggle('open');
            overlay.classList.toggle('open');
        });

        overlay.addEventListener('click', () => {
            sidebar.classList.remove('open');
            overlay.classList.remove('open');
        });

        // 媒体项选择功能
        const mediaItems = document.querySelectorAll('.media-item');
        mediaItems.forEach(item => {
            item.addEventListener('click', (e) => {
                if (e.target.tagName !== 'BUTTON' && !e.target.closest('button')) {
                    item.classList.toggle('selected');
                }
            });
        });

        // 模拟上传功能
        const uploadArea = document.querySelector('.upload-area');
        const uploadBtn = uploadArea.querySelector('.btn');

        uploadArea.addEventListener('dragover', (e) => {
            e.preventDefault();
            uploadArea.style.borderColor = 'var(--primary-color)';
            uploadArea.style.backgroundColor = 'rgba(52, 152, 219, 0.05)';
        });

        uploadArea.addEventListener('dragleave', () => {
            uploadArea.style.borderColor = 'var(--border-color)';
            uploadArea.style.backgroundColor = 'var(--card-bg)';
        });

        uploadArea.addEventListener('drop', (e) => {
            e.preventDefault();
            uploadArea.style.borderColor = 'var(--border-color)';
            uploadArea.style.backgroundColor = 'var(--card-bg)';
            alert('文件已上传！');
        });

        uploadBtn.addEventListener('click', () => {
            alert('打开文件选择器');
        });
    </script>
</body>

</html>